  upstream <%= @app_name %> {
    server unix:/shared_path/sockets/puma.sock;
  }

  server {
    listen 80;
    server_name example.com;

    # inserted block ----- start

    location / {
      proxy_set_header X-Real-IP $remote_addr;
      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header Host $http_host;
      proxy_pass http://<%= @app_name %>;
    }

    location ~ ^/(assets)/  {
      gzip_static on; # to serve pre-gzipped version
      expires max;
      add_header  Cache-Control public;
    }

    # inserted block ----- end
  }
